package com.qut.qut_01.controller;

import com.qut.qut_01.mapper.Login_Reg_Mapper;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;
import java.util.Map;

@RestController
@RequestMapping("/user")
public class Login_Reg_Controller {

    @Resource
    private com.qut.qut_01.mapper.Login_Reg_Mapper LOGIN_REG_MAPPER;

    @RequestMapping("/Account_reg")
    public int reg(@RequestParam Map<String,String> param){
        int row = 0;
        System.out.println(param);
        row = LOGIN_REG_MAPPER.account_reg(param);
        return row;
    }

    @RequestMapping("/Account_Login")
    public Map<String ,Object> Account_Login(@RequestParam Map<String,Object> param){
        Map<String,Object> user=null;
        user=LOGIN_REG_MAPPER.account_Login(param);
        return user;
    }



}
